package com.temi.iot.controller;


import com.temi.iot.common.constant.result.Result;
import com.temi.iot.service.ISysLoginService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author one
 * @since 2019-12-11
 */
@Api(description = "登录")
@RestController
@RequestMapping("/sys-login")
public class SysLoginController {

    @Autowired
    private ISysLoginService sysLoginService;


    @ApiOperation("登录")
    @GetMapping
    public Result login(String userName,String password) throws Exception {
        return sysLoginService.login(userName,password);
    }

}
